﻿using System;

namespace MTP.Dispatch
{
    /// <summary>
    /// 
    /// </summary>
    abstract class DispatchBase
    {
        /// <summary>
        /// 
        /// </summary>
        /// <param name="guid">唯一键</param>
        /// <param name="packageType">数据类型</param>
        /// <param name="data">数据</param>
        /// <param name="clientId">客户端id</param>
        /// <returns></returns>
        public abstract void Receive(Guid guid, MTPPackage package, string clientId);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="socket"></param>
        public virtual void Accept(SocketStream socket)
        {

        }
        /// <summary>
        /// 
        /// </summary>
        /// <param name="clientId"></param>
        public abstract void Dispose(string clientId);
    }
}
